<template>
  <div id="SearchQuestionVOView">
    <a-form layout="inline">
      <a-form-item field="title" label="名称" style="min-width: 240px">
        <a-input v-model="title" placeholder="请输入名称" />
      </a-form-item>
      <a-form-item field="tags" label="标签" style="min-width: 240px">
        <a-input-tag v-model="tags" placeholder="请输入标签" />
      </a-form-item>
      <a-form-item>
        <a-button type="primary" @click="doSubmit">搜索</a-button>
      </a-form-item>
    </a-form>
  </div>
</template>

<script setup lang="ts">
import { defineEmits, ref } from "vue";

const emits = defineEmits(["getResult"]);
const title = ref("");
const tags = ref([]);

/**
 * 获取父组件的数据
 */
const doSubmit = async () => {
  emits("getResult", title.value, tags.value);
};
</script>
<style scoped>
#SearchQuestionVOView {
}
</style>
